import Vue from 'vue'
import App from './App.vue'
import VueRouter from 'vue-router'
import router from './router'
import ElementUI from 'element-ui'
import axios from 'axios'
import 'element-ui/lib/theme-chalk/index.css';
import VideoPlayer from 'vue-video-player'
import tim from 'tim'
import TIM from 'tim-js-sdk'
import 'vue-video-player/src/custom-theme.css'
import 'video.js/dist/video-js.css'
import VueDirectiveImagePreviewer from 'vue-directive-image-previewer'
import 'vue-directive-image-previewer/dist/assets/style.css'
import clipboard from 'clipboard';
import toTop from '../src/components/getcon'

import BaiduMap from 'vue-baidu-map';
Vue.use(BaiduMap, {
    /* Visit http://lbsyun.baidu.com/apiconsole/key for details about app key. */
  ak: '4wCTuvgtkfbqkOLQAv9jNFiP6qhYIH0E'
})
Vue.prototype.clipboard = clipboard//点击复制功能
Vue.use(VueDirectiveImagePreviewer) 
window.tim = tim
window.TIM = TIM

// fundebugVue(fundebug, Vue);
Vue.prototype.$axios = axios//全局注册，使用方法为:this.$axios 
Vue.use(VideoPlayer)//全局使用vide组件
Vue.prototype.tim = tim
Vue.prototype.TIM = TIM

Vue.use(toTop)//全局方法

//用于生成uuid
Vue.prototype.S4 = function(){
  return (((1+Math.random())*0x10000)|0).toString(16).substring(1);
}
Vue.prototype.guid = function() {
  return (this.S4()+this.S4()+"-"+this.S4()+"-"+this.S4()+"-"+this.S4()+"-"+this.S4()+this.S4()+this.S4());
}
Vue.use(ElementUI);
Vue.config.productionTip = false
Vue.use(VueRouter)
new Vue({
  router,
  render: h => h(App)
}).$mount('#app')
